<%@ page language="java" import="java.util.*,com.lmpop.trade.ti_attach.*" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
   	<%
   		String attach_root_id = "",img_type="",req_type="",old_attach_root_id="";
   		if(request.getParameter("old_attach_root_id") != null && !request.getParameter("old_attach_root_id").equals(""))
			{
				old_attach_root_id = request.getParameter("old_attach_root_id");
			}
   		if(request.getParameter("attach_root_id")!=null){
   			attach_root_id = request.getParameter("attach_root_id");
   		} 
   		if(request.getParameter("img_type")!=null){
   			img_type = request.getParameter("img_type");
   		}
 			if(request.getParameter("req_type")!=null){
   			req_type = request.getParameter("req_type");
   		}
   		Ti_attachInfo attachInfo = new Ti_attachInfo();
   		List aList = attachInfo.getListByAttachrootid(attach_root_id);
   		boolean isEixst = false;
			if(aList!=null && aList.size()>0) isEixst = true;	
   		
   	%>
   	<input type="hidden" name="attach_root_id" value="<%=attach_root_id%>" />
 
   	<input type="hidden" name="attach_sign" value="insert" />
    	<%
   		if(req_type.equals("b2c")){%>
   	<input type="button" class="buttoncss" name="uploadImgWin" value="图片管理" onclick="window.open('/b2cimageUpload.html?img_type=<%=img_type%>&attach_root_id=<%=attach_root_id%>');"/>
   		<%}else	if(req_type.equals("sale")){%>
   	<input type="button" class="buttoncss" name="uploadImgWin" value="图片管理" onclick="window.open('/saleimageUpload.html?img_type=<%=img_type%>&attach_root_id=<%=attach_root_id%>&old_attach_root_id=<%=old_attach_root_id%>');"/>
   		<%}else{%>
   	<input type="button" class="buttoncss" name="uploadImgWin" value="图片管理" onclick="window.open('/imageUpload.html?img_type=<%=img_type%>&attach_root_id=<%=attach_root_id%>');"/>
   		<%}
   	 %>

   	<%if(isEixst){%><img src="/program/images/ico_img.gif" style="vertical-align:middle;" /><%}%>